Skip to content

feat(notification): add support for Telnyx notifications#371

Open
breml wants to merge 2 commits into
masterfrom
feature-347-feat-notification-add-support-for-telnyx-notifications
Open

feat(notification): add support for Telnyx notifications#371
breml wants to merge 2 commits into
masterfrom
feature-347-feat-notification-add-support-for-telnyx-notifications

Conversation

@breml

@breml breml commented Jun 12, 2026

Copy link
Copy Markdown
Owner

Overview

Adds the uptimekuma_notification_telnyx resource and data source for sending SMS notifications via the Telnyx communications API. The client gained support for Telnyx in v0.4.0 (Uptime Kuma 2.3.2).

Changes

  • resource_notification_telnyx.go — model + CRUD using notification.Telnyx, including ImportState. The optional messaging_profile_id maps to the client's *string field.
  • data_source_notification_telnyx.go — lookup by ID (readByID) and by name (readByName).
  • Acceptance tests for the resource (create/update + import state) and data source (by name + by ID).
  • examples/ for the resource and data source.
  • Registered NewNotificationTelnyxResource / NewNotificationTelnyxDataSource in provider.go.
  • Generated documentation.

Attributes

Attribute Type Required Notes
api_key string yes (sensitive) Telnyx API key
messaging_profile_id string no Telnyx messaging profile ID
phone_number string yes Sender (E.164)
to_number string yes Recipient (E.164)

Plus the standard notification base attributes.

Follow-up fixes

  • Log the assigned ID via tflog.Info after Create, consistent with other notification resources.
  • Handle kuma.ErrNotFound in Delete so terraform destroy succeeds if the notification was already removed in Uptime Kuma.
  • Improve the data source's type-mismatch error to include the actual type and requested ID.
  • Expand acceptance test assertions to cover is_default, apply_existing, and id.

Verification

  • task fmt — clean
  • task lint — 0 issues
  • task testacc — all acceptance tests pass (resource, data source, import state)
  • task generate-docs — docs regenerated

Closes #347

Add the uptimekuma_notification_telnyx resource and data source for
sending SMS notifications via the Telnyx communications API. The client
gained support for Telnyx in v0.4.0 (Uptime Kuma 2.3.2).

Closes #347
@breml breml self-assigned this Jun 12, 2026
Add `tflog.Info` after `Create` to log the assigned ID, consistent
with other notification resources. Handle `kuma.ErrNotFound` in
`NotificationTelnyxResource.Delete` so `terraform destroy` succeeds
even when the notification was already removed in Uptime Kuma.

Improve the type-mismatch error in `NotificationTelnyxDataSource` to
include the actual notification type and requested ID, matching the
`HaloPSA` data source pattern.

Expand acceptance test assertions in both resource and data source
tests to cover `is_default`, `apply_existing`, and `id`.

Co-Authored-By: Lucas Bremgartner <lucas@bremis.ch>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(notification): add support for Telnyx notifications

1 participant